package com.ls.cloud.auth.dao;

import com.ls.cloud.auth.entity.AuthUser;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.CrudRepository;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.stereotype.Repository;

import java.util.Optional;

/**
 * @author: candy33
 * @Date: 2022/05/12 0:18
 * com.ls.cloud.auth.dao
 */
@Repository
public interface AuthUserDao extends CrudRepository<AuthUser, String>, JpaSpecificationExecutor<String> {

    /**
     * 根据用户登录账号查询用户信息
     * @param username
     * @return
     */
    Optional<AuthUser> findByUsername(String username);
}
